package com.asteroid20.loginsystem.service;

import com.asteroid20.loginsystem.entity.User;
import com.asteroid20.loginsystem.repository.UserRepository;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class UserService {
    @Autowired
    private UserRepository repo;

    public List<User> findAllUser(){
        return repo.findAll();
    }
    public void saveUser(User user){
        repo.save(user);
    }

}
